package com.ruoyi.cinema.service.impl;

import java.util.List;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.cinema.mapper.SchedulePromoAreaMapper;
import com.ruoyi.cinema.domain.SchedulePromoArea;
import com.ruoyi.cinema.service.ISchedulePromoAreaService;

/**
 * 排期分区优惠信息Service业务层处理
 *
 * @author HHAOYU
 * @date 2020-12-13
 */
@Service
public class SchedulePromoAreaServiceImpl extends ServiceImpl<SchedulePromoAreaMapper, SchedulePromoArea> implements ISchedulePromoAreaService  {
    @Autowired
    private SchedulePromoAreaMapper schedulePromoAreaMapper;

    /**
     * 查询排期分区优惠信息
     *
     * @param id 排期分区优惠信息ID
     * @return 排期分区优惠信息
     */
    @Override
    public SchedulePromoArea selectSchedulePromoAreaById(Long id)
    {
        return schedulePromoAreaMapper.selectSchedulePromoAreaById(id);
    }

    /**
     * 查询排期分区优惠信息列表
     *
     * @param schedulePromoArea 排期分区优惠信息
     * @return 排期分区优惠信息
     */
    @Override
    public List<SchedulePromoArea> selectSchedulePromoAreaList(SchedulePromoArea schedulePromoArea)
    {
        return schedulePromoAreaMapper.selectSchedulePromoAreaList(schedulePromoArea);
    }

    /**
     * 新增排期分区优惠信息
     *
     * @param schedulePromoArea 排期分区优惠信息
     * @return 结果
     */
    @Override
    public int insertSchedulePromoArea(SchedulePromoArea schedulePromoArea)
    {
        return schedulePromoAreaMapper.insertSchedulePromoArea(schedulePromoArea);
    }

    /**
     * 修改排期分区优惠信息
     *
     * @param schedulePromoArea 排期分区优惠信息
     * @return 结果
     */
    @Override
    public int updateSchedulePromoArea(SchedulePromoArea schedulePromoArea)
    {
        return schedulePromoAreaMapper.updateSchedulePromoArea(schedulePromoArea);
    }

    /**
     * 批量删除排期分区优惠信息
     *
     * @param ids 需要删除的排期分区优惠信息ID
     * @return 结果
     */
    @Override
    public int deleteSchedulePromoAreaByIds(Long[] ids)
    {
        return schedulePromoAreaMapper.deleteSchedulePromoAreaByIds(ids);
    }

    /**
     * 删除排期分区优惠信息信息
     *
     * @param id 排期分区优惠信息ID
     * @return 结果
     */
    @Override
    public int deleteSchedulePromoAreaById(Long id)
    {
        return schedulePromoAreaMapper.deleteSchedulePromoAreaById(id);
    }
}
